﻿using System;
using System.Collections.Generic;
using System.Text;

namespace GoogleMaps
{
	/// <summary>
	/// A collapsible overview mini-map in the corner of the main map for reference location and 
	/// navigation (through dragging).
	/// </summary>
	public class GOverviewMapControl : GControl
	{
		/// <summary>
		/// Renders the control by appending it to the stringbuilder that contains the JavaScript 
		/// for the related Google Map.
		/// </summary>
		/// <param name="js">A string builder containing the javascript that goes with the Google Map.</param>
		/// <param name="javaScriptVariableName">The namve of the JavaScript variable that is holding the map.</param>
		public override void Render(StringBuilder js, string javaScriptVariableName)
		{
			js.AppendFormat("{0}.addControl(new GOverviewMapControl());", javaScriptVariableName);
		}
	}
}
